package framework.mapstruct;

import java.util.Date;

/**
 * @author ME
 * @date 2020/11/3
 */
public class CarPo {

    private Integer id;
    private String brand;
    private String carName;
    private Date createTime;
    private String origin;

    public CarPo() {
    }

    public CarPo(Integer id, String brand, String carName, Date createTime, String origin) {
        this.id = id;
        this.brand = brand;
        this.carName = carName;
        this.createTime = createTime;
        this.origin = origin;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getBrand() {
        return brand;
    }

    public void setBrand(String brand) {
        this.brand = brand;
    }

    public String getCarName() {
        return carName;
    }

    public void setCarName(String carName) {
        this.carName = carName;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public String getOrigin() {
        return origin;
    }

    public void setOrigin(String origin) {
        this.origin = origin;
    }

    @Override
    public String toString() {
        return "CarPo(id=" + this.id + ", brand=" + this.brand + ", carName=" + this.carName + ", createTime=" + this.createTime + ")";
    }

    public static CarPo.CarPoBuilder builder() {
        return new CarPo.CarPoBuilder();
    }

    public static class CarPoBuilder {
        private Integer id;
        private String brand;
        private String carName;
        private Date createTime;
        private String origin;

        CarPoBuilder() {
        }

        public CarPo.CarPoBuilder id(Integer id) {
            this.id = id;
            return this;
        }

        public CarPo.CarPoBuilder brand(String brand) {
            this.brand = brand;
            return this;
        }

        public CarPo.CarPoBuilder carName(String carName) {
            this.carName = carName;
            return this;
        }

        public CarPo.CarPoBuilder createTime(Date createTime) {
            this.createTime = createTime;
            return this;
        }

        public CarPo.CarPoBuilder origin(String origin) {
            this.origin = origin;
            return this;
        }

        public CarPo build() {
            return new CarPo(this.id, this.brand, this.carName, this.createTime, this.origin);
        }

        @Override
        public String toString() {
            return "CarPo.CarPoBuilder(id=" + this.id + ", brand=" + this.brand + ", carName=" + this.carName + ", createTime=" + this.createTime + ")";
        }
    }

}
